/*************************************************
  File name     : xusbdevicedef.h
  Module        : usb-static
  Author        : scar.chen
  Version       : 1.0
  Created on    : 2019-12-26
  Description   :
      struct of x-usb device

  Modify History:
  1. Date:        Author:         Modification:
*************************************************/
#ifndef xusbdevicedef_H
#define xusbdevicedef_H

#ifdef _WIN32
    #ifndef LIBUSB_PATH_MAX
        #define LIBUSB_PATH_MAX 512
    #endif
#endif


/**
 * @file xusbdevicedef.h
 * @brief struct of x-usb device.
 *
 */
#pragma pack(push,1)
typedef struct _XUSBDevice
{
    /** vendor-id */
    unsigned short vid;
    /** product-id */
    unsigned short pid;
    /** serialnumber */
    char szSerialNumber[64];
    /** bus number */
    unsigned int bus_number;
    /** device address */
    unsigned int device_address;
#ifdef _WIN32
    /** 1 means usbscsi */
    int  isUSBSCSI;
    /** device path */
    char szDevicePath[LIBUSB_PATH_MAX];
    /** drive   */
    char chDrive;
#endif
    /** multi-device relation */
    void *extraPtr;
} TXUSBDevice, *PXUSBDevice;

#pragma pack(pop)


#endif